package com.zr.repertory.affiliation.mapper;

import com.zr.repertory.affiliation.model.pojo.LegalPerson;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @ClassName LegalPersonMapper
 * @Description TODO
 * @Author Jiakui_Ma
 * @Date 2019/11/21 10:56
 */
@Mapper
public interface LegalPersonMapper {


    @Select("select lp.legalPersonName ,lp.legalPersonId  id ,lp.legalPersonId from legalperson lp left join user u on lp.userId = u.id where u.id =#{s}")
    List<LegalPerson> queryAll(Integer s);
    @Select("select * from legalperson  where legalPersonId =#{legalPersonId}")
    LegalPerson queryById(Integer legalPersonId);
}
